package day11;

import java.util.TreeMap;

public class StudentTest {
    public static void main(String[] args) {
        TreeMap<Student,String> tm=new TreeMap<>();
        Student s=new Student("xiahua",23);
        Student s1=new Student("tiali",22);
        Student s2=new Student("liadan",24);
        tm.put(s,"北京");
        tm.put(s1,"天津");
        tm.put(s2,"日本");
        tm.forEach((Student key,String value)->
            System.out.println(key +value)
        );
    }
}
